# Maintainer: Christian Hesse <mail@eworm.de>
# Contributor: David Phillips <dbphillipsnz at _remove this part if you want_ gmail dot com>

pkgname=abduco
pkgver=0.6
pkgrel=6
pkgdesc='Tool for session {at,de}tach support which allows a process to run independently from its controlling terminal'
arch=('loong64' 'x86_64')
url='http://www.brain-dump.org/projects/abduco/'
license=('custom:ISC')
source=("http://www.brain-dump.org/projects/${pkgname}/${pkgname}-${pkgver}.tar.gz"
        'config.h')
sha512sums=('3b70a5cc10f0a2743dcbdf6eebdcfcee0e4f4ff8c6ce0bf0aa9f55c3fa85ab43aa659997735e063eab36aba69f91be7bb5519f3f632bff1b9098f5179165c1f2'
            '2860d87984ae1dcfec98112e128a6e481b2a8a87ffc11131d14c2b5937a15f2a09896c2f62bfc802e7d0befa82e111a883c09958db9f544ec2532458d92cd5f4')

prepare () {
	cd "${srcdir}/${pkgname}-${pkgver}"

	cp "${srcdir}/config.h" .
}

build () {
	cd "${srcdir}/${pkgname}-${pkgver}"

	make all
}

package () {
	cd "${srcdir}/${pkgname}-${pkgver}"

	make PREFIX='/usr' DESTDIR="${pkgdir}" install
	install -D -m0644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
